Extension::MongoDBAddRecord Method
Syntax
c AddRecord(C data)
Arguments
- data
JSON for the document to add.
Description
Adds a document db record using 'id'.
dim mongo as extension::MongoDB = extension::MongoDB::Create("mongodb://localhost:27017","TestDatabase","flowers") mongo.AddRecord(<<%json% { "Id": "00000062", "Picture": "=filename_decode(\"Hires\\rudbekia.jpg\")", "Imagedate": "08/12/2001", "Keywords": "rudbekia daisy yellow" } %json%)
This example passes hardcoded JSON, generally users would get thier JSON supplied from another function.